<!doctype html>
<html lang="zh-CN">
<head>
    <!-- 必须的 meta 标签 -->
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <link rel="stylesheet" href="./static/css/font.css">
    <!-- Bootstrap 的 CSS 文件 -->
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.6.2/dist/css/bootstrap.min.css"
          integrity="sha384-xOolHFLEh07PJGoPkLv1IbcEPTNtaed2xpHsD9ESMhqIYd0nLMwNLD69Npy4HI+N" crossorigin="anonymous">
    <link rel="stylesheet" href="./static/css/mycs.css">
    <title>{% block title %}{% endblock %}</title>
</head>
<body>
<!-- JavaScript 文件是可选的。从以下两种建议中选择一个即可！ -->
<!-- 选项 1：jQuery 和 Bootstrap 集成包（集成了 Popper） -->
<script src="https://cdn.jsdelivr.net/npm/jquery@3.5.1/dist/jquery.slim.min.js"
        integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj"
        crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.2/dist/js/bootstrap.bundle.min.js"
        integrity="sha384-7ymO4nGrkm372HoSbq1OY2DP4pEZnMiA+E0F3zPr+JQQtQ82gQ1HPY3QIVtztVua"
        crossorigin="anonymous"></script>
<!-- 选项 2：Popper 和 Bootstrap 的 JS 插件各自独立 -->
<!--
<script src="https://cdn.jsdelivr.net/npm/jquery@3.5.1/dist/jquery.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js" integrity="sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.2/dist/js/bootstrap.min.js" integrity="sha384-Lge2E2XotzMiwH69/MXB72yLpwyENMiOKX8zS8Qo7LDCvaBIWGL+GlRQEKIpYR04" crossorigin="anonymous"></script>
-->

<nav class="navbar navbar-expand-lg navbar-dark bg-primary">
    <div class="collapse navbar-collapse" id="navbarSupportedContent">
        <ul class="navbar-nav mr-auto">
            <li class="nav-item active">
                {% if 'username' in session %}
                <a class="nav-link iconfont icon-a-renyuanwode" href="/">返回主页<span class="sr-only">(current)</span></a>
                {% else %}
                <a class="nav-link disable iconfont icon-a-renyuanwode">返回主页<span class="sr-only">(current)</span></a>
                {% endif %}
            </li>
            <li class="nav-item active">
                {% if 'username' in session %}
                <a class="nav-link iconfont icon-bianzu" href="https://www.baidu.com/">百度</a>
                {% else %}
                <a class="nav-link disable iconfont icon-bianzu">百度</a>
                {% endif %}
            </li>
            <li class="nav-item active">
                {% if 'username' in session %}
                <a class="nav-link iconfont icon-rili" href="/score">成绩</a>
                {% else %}
                <a class="nav-link disable">成绩</a>
                {% endif %}
            </li>
            <li class="nav-item active">
                {% if 'username' in session %}
                <a class="nav-link iconfont icon-zhufu" href="/wish">祝福</a>
                {% else %}
                <a class="nav-link disable">祝福</a>
                {% endif %}
            </li>
            <li class="nav-item active">
                {% if 'username' in session %}
                {% if session['role'] == '管理员' %}
                <a class="nav-link iconfont icon-shezhi" href="/myweb">系统设置</a>
                {% else %}
                <a class="nav-link iconfont icon-yonghuguanli" href="/about">关于软件</a>
                {% endif %}
                {% else %}
                <a class="nav-link disable iconfont icon-shezhi">系统设置</a>
                {% endif %}
            </li>

        </ul>
        {% if 'username' not in session %}
        <a class="btn btn-outline-success my-2 my-sm-0" href="/login">登录</a>
        {% else %}
        <a class="btn btn-outline-success my-2 my-sm-0" href="/logot">退出</a>
        {% endif %}
    </div>
</nav>
{% block body %}{% endblock %}